<?php if (!defined('THINK_PATH')) exit(); /*a:1:{s:62:"F:\yxl\tp5.com\public/../application/admin\view\index\img.html";i:1561124725;}*/ ?>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>图片轮播</title>
    <link rel="stylesheet" href="/static/layui/css/layui.css">
</head>
<body >

<!--<fieldset class="layui-elem-field layui-field-title" style="margin-top: 50px;">-->
<!--<legend>填充轮播元素 - 以图片为例</legend>-->
<!--</fieldset>-->
<div>
    <a href="/admin/index/index" color="red" style="margin-left:50px;"><h2>返回博客列表</h2></a>
</div>
<div class="layui-carousel" id="test10" style="margin:0 auto">
    <p style="color:#009688;font-size:25px;text-align:center;">图片轮播展示</p>
    <div carousel-item="">
        <?php if(is_array($row) || $row instanceof \think\Collection || $row instanceof \think\Paginator): $i = 0; $__LIST__ = $row;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;?>
        <img src="<?php echo $vo['path_name']; ?>" alt="">
        <?php endforeach; endif; else: echo "" ;endif; ?>
    </div>
    <br>
</div>

</body>
</html>
<script src="/static/layui/layui.js"></script>
<script>
    layui.use('carousel', function(){
        var carousel = layui.carousel;
        //图片轮播
        carousel.render({
            elem: '#test10'
            ,width: '600px'
            ,height: '440px'
            ,interval: 1000
        });
    });
</script>